package com.guhus.ec.service.seller.impl;

import com.guhus.ec.mapper.seller.CategoryMapper;
import com.guhus.ec.pojo.seller.Brand;
import com.guhus.ec.pojo.seller.Cate1;
import com.guhus.ec.pojo.seller.Cate2;
import com.guhus.ec.pojo.seller.Cate3;
import com.guhus.ec.service.seller.CategoryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CategoryServiceImpl implements CategoryService {
    @Autowired
    CategoryMapper categoryMapper;


    @Override
    public Cate1 selectCate1ById(Integer id) {
        return categoryMapper.selectCate1ById(id);
    }

    @Override
    public Cate2 selectCate2ById(Integer id) {
        return categoryMapper.selectCate2ById(id);
    }

    @Override
    public Cate3 selectCate3ById(Integer id) {
        return categoryMapper.selectCate3ById(id);
    }

    @Override
    public Cate3 selectBrandById(Integer id) {
        return categoryMapper.selectBrandById(id);
    }

    @Override
    public List<Cate1> selectAllCate1s() {
        return categoryMapper.selectAllCate1s();
    }

    @Override
    public List<Cate2> selectAllCate2s() {
        return categoryMapper.selectAllCate2s();
    }

    @Override
    public List<Cate3> selectAllCate3s() {
        return categoryMapper.selectAllCate3s();
    }

    @Override
    public List<Brand> selectAllBrands() {
        return categoryMapper.selectAllBrands();
    }

    @Override
    public List<Cate2> selectCate2ByPid(Integer pid) {
        return categoryMapper.selectCate2ByPid(pid);
    }

    @Override
    public List<Cate3> selectCate3ByPid(Integer pid) {
        return categoryMapper.selectCate3ByPid(pid);
    }

    @Override
    public Cate3 selectCate3ByBrandId(Integer id) {
        return categoryMapper.selectCate3ByBrandId(id);
    }

    @Override
    public List<Brand> selectAllBrandsByCate3Id(Integer id) {
        return categoryMapper.selectAllBrandsByCate3Id(id);
    }
}
